import { createRouter, createWebHistory } from 'vue-router'
import HomeView from '../views/HomeView.vue'

const routes = [
  {
    path: '/',
    name: 'home',
    component: HomeView,
    redirect:'/index',
    children:[
      {path:'/index',component:()=>import('../views/IndexView')},
      {path:'/singer',component:()=>import('../views/singerView')},
      {path:'/album',component:()=>import('../views/albumView')},
      {path:'/other',component:()=>import('../views/otherView')}
    ]
  },
]

const router = createRouter({
  history: createWebHistory(process.env.BASE_URL),
  routes
})

export default router
